import java.awt.Component;
import java.awt.Container;
import java.awt.Dimension;
import java.awt.Font;
import java.awt.Insets;
import java.awt.Point;
import java.awt.Rectangle;
import java.awt.event.ActionEvent;
import javax.swing.JButton;
import javax.swing.JCheckBox;
import javax.swing.JEditorPane;
import javax.swing.JFrame;
import javax.swing.JLabel;
import javax.swing.JPanel;
import javax.swing.JScrollPane;
import javax.swing.JSeparator;
import javax.swing.JSlider;
import javax.swing.JTabbedPane;
import org.rsbot.script.ScriptManifest;

public class VoltrexApeAtoll$ApeAtollGUI extends JFrame
{
  private JTabbedPane tabbedPane1;
  private JPanel panel1;
  private JCheckBox checkBox1;
  private JCheckBox checkBox2;
  private JSeparator separator1;
  private JCheckBox checkBox3;
  private JSlider slider1;
  private JLabel label4;
  private JLabel label5;
  private JLabel label6;
  private JScrollPane scrollPane1;
  private JEditorPane editorPane1;
  private JLabel label1;
  private JLabel label2;
  private JLabel label3;
  private JButton button1;
  private JScrollPane scrollPane2;
  private JEditorPane editorPane2;

  public VoltrexApeAtoll$ApeAtollGUI(VoltrexApeAtoll paramVoltrexApeAtoll)
  {
    initComponents();
  }

  private void button1ActionPerformed(ActionEvent paramActionEvent) {
    VoltrexApeAtoll.access$3202(this.this$0, this.checkBox1.isSelected());
    VoltrexApeAtoll.access$3302(this.this$0, this.checkBox2.isSelected());
    VoltrexApeAtoll.access$3402(this.this$0, this.checkBox3.isSelected());
    int i = this.slider1.getValue();

    if (i == 100)
      VoltrexApeAtoll.access$3502(this.this$0, 2);
    else if (i == 90)
      VoltrexApeAtoll.access$3502(this.this$0, 3);
    else if (i == 80)
      VoltrexApeAtoll.access$3502(this.this$0, 4);
    else if (i == 70)
      VoltrexApeAtoll.access$3502(this.this$0, 5);
    else if (i == 60)
      VoltrexApeAtoll.access$3502(this.this$0, 6);
    else if (i == 50)
      VoltrexApeAtoll.access$3502(this.this$0, 7);
    else if (i == 40)
      VoltrexApeAtoll.access$3502(this.this$0, 8);
    else if (i == 30)
      VoltrexApeAtoll.access$3502(this.this$0, 9);
    else if (i == 20)
      VoltrexApeAtoll.access$3502(this.this$0, 10);
    else if (i == 10) {
      VoltrexApeAtoll.access$3502(this.this$0, 12);
    }

    VoltrexApeAtoll.access$3602(this.this$0, false);
    dispose();
  }

  private void initComponents()
  {
    this.tabbedPane1 = new JTabbedPane();
    this.panel1 = new JPanel();
    this.checkBox1 = new JCheckBox();
    this.checkBox2 = new JCheckBox();
    this.separator1 = new JSeparator();
    this.checkBox3 = new JCheckBox();
    this.slider1 = new JSlider();
    this.label4 = new JLabel();
    this.label5 = new JLabel();
    this.label6 = new JLabel();
    this.scrollPane1 = new JScrollPane();
    this.editorPane1 = new JEditorPane();
    this.label1 = new JLabel();
    this.label2 = new JLabel();
    this.label3 = new JLabel();
    this.button1 = new JButton();
    this.scrollPane2 = new JScrollPane();
    this.editorPane2 = new JEditorPane();

    Container localContainer = getContentPane();
    localContainer.setLayout(null);

    this.panel1.setLayout(null);

    this.checkBox1.setText("Log out when low HP and out of food");
    this.checkBox1.setSelected(true);
    this.panel1.add(this.checkBox1);
    this.checkBox1.setBounds(new Rectangle(new Point(5, 5), this.checkBox1.getPreferredSize()));

    this.checkBox2.setText("Pick pineapples (have a knife in inventory)");
    this.checkBox2.setSelected(true);
    this.panel1.add(this.checkBox2);
    this.checkBox2.setBounds(new Rectangle(new Point(5, 30), this.checkBox2.getPreferredSize()));
    this.panel1.add(this.separator1);
    this.separator1.setBounds(20, 60, 225, 2);

    this.checkBox3.setText("Check for updates on startup");
    this.checkBox3.setSelected(true);
    this.panel1.add(this.checkBox3);
    this.checkBox3.setBounds(new Rectangle(new Point(5, 70), this.checkBox3.getPreferredSize()));

    this.slider1.setSnapToTicks(true);
    this.slider1.setPaintTicks(true);
    this.slider1.setPaintLabels(true);
    this.slider1.setMinimum(10);
    this.slider1.setMajorTickSpacing(10);
    this.slider1.setValue(60);
    this.panel1.add(this.slider1);
    this.slider1.setBounds(10, 170, 240, this.slider1.getPreferredSize().height);

    this.label4.setText("Mouse speed:");
    this.label4.setFont(this.label4.getFont().deriveFont(this.label4.getFont().getStyle() | 0x1));
    this.panel1.add(this.label4);
    this.label4.setBounds(new Rectangle(new Point(5, 135), this.label4.getPreferredSize()));

    this.label5.setText("Slow");
    this.panel1.add(this.label5);
    this.label5.setBounds(new Rectangle(new Point(5, 155), this.label5.getPreferredSize()));

    this.label6.setText("Fast");
    this.panel1.add(this.label6);
    this.label6.setBounds(new Rectangle(new Point(230, 155), this.label6.getPreferredSize()));

    Dimension localDimension = new Dimension();
    Rectangle localRectangle;
    for (int i = 0; i < this.panel1.getComponentCount(); i++) {
      localRectangle = this.panel1.getComponent(i).getBounds();
      localDimension.width = Math.max(localRectangle.x + localRectangle.width, localDimension.width);
      localDimension.height = Math.max(localRectangle.y + localRectangle.height, localDimension.height);
    }
    Insets localInsets1 = this.panel1.getInsets();
    localDimension.width += localInsets1.right;
    localDimension.height += localInsets1.bottom;
    this.panel1.setMinimumSize(localDimension);
    this.panel1.setPreferredSize(localDimension);

    this.tabbedPane1.addTab("Options", this.panel1);

    this.editorPane1.setEditable(false);
    this.editorPane1.setText("Start AT the course with a Monkey Greegree\nequipted(must be a ninja greegree). If you enabled the option 'Pick pineapples', then you must have a\nknife in your inventory.");
    this.scrollPane1.setViewportView(this.editorPane1);

    this.tabbedPane1.addTab("Instructions", this.scrollPane1);

    localContainer.add(this.tabbedPane1);
    this.tabbedPane1.setBounds(0, 0, 270, 265);

    this.label1.setText("Ape Atoll course");
    this.label1.setFont(this.label1.getFont().deriveFont(this.label1.getFont().getStyle() | 0x1, this.label1.getFont().getSize() + 2.0F));
    localContainer.add(this.label1);
    this.label1.setBounds(new Rectangle(new Point(275, 20), this.label1.getPreferredSize()));

    this.label2.setText("by Voltrex");
    localContainer.add(this.label2);
    this.label2.setBounds(new Rectangle(new Point(275, 35), this.label2.getPreferredSize()));

    this.label3.setText("Version " + VoltrexApeAtoll.access$3700(this.this$0).version());
    localContainer.add(this.label3);
    this.label3.setBounds(new Rectangle(new Point(275, 60), this.label3.getPreferredSize()));

    this.button1.setText("Start Script");
    this.button1.setFont(this.button1.getFont().deriveFont(this.button1.getFont().getStyle() | 0x1));
    this.button1.addActionListener(new VoltrexApeAtoll.ApeAtollGUI.1(this));

    localContainer.add(this.button1);
    this.button1.setBounds(new Rectangle(new Point(280, 235), this.button1.getPreferredSize()));

    this.editorPane2.setEditable(false);
    this.editorPane2.setText("1.30: New GUI");
    this.scrollPane2.setViewportView(this.editorPane2);

    localContainer.add(this.scrollPane2);
    this.scrollPane2.setBounds(275, 75, 110, 155);

    localDimension = new Dimension();
    for (int j = 0; j < localContainer.getComponentCount(); j++) {
      localRectangle = localContainer.getComponent(j).getBounds();
      localDimension.width = Math.max(localRectangle.x + localRectangle.width, localDimension.width);
      localDimension.height = Math.max(localRectangle.y + localRectangle.height, localDimension.height);
    }
    Insets localInsets2 = localContainer.getInsets();
    localDimension.width += localInsets2.right;
    localDimension.height += localInsets2.bottom;
    localContainer.setMinimumSize(localDimension);
    localContainer.setPreferredSize(localDimension);

    pack();
    setLocationRelativeTo(getOwner());
  }
}